package com.coincalf.exchange.service;

import com.baomidou.mybatisplus.service.IService;
import com.coincalf.exchange.entity.ForexOpenPositionOrder;
import com.coincalf.framework.enums.OpenPositionOrderStatus;

import java.math.BigDecimal;

/**
 * <p>
 * 开仓订单信息 服务类
 * </p>
 *
 * @author qiang
 * @since 2018-05-12
 */
public interface ForexOpenPositionOrderService extends IService<ForexOpenPositionOrder> {

    /**
     * 平仓修改开仓信息
     * @param openId 开仓订单号
     * @param unlockMargin 返还保证金
     * @param closeVolume 平仓量
     * @param status 状态
     */
    void closePosition(long openId, BigDecimal unlockMargin, BigDecimal closeVolume, OpenPositionOrderStatus status);
}
